package com.docios.cookbook2.entity;

import androidx.annotation.NonNull;
import androidx.room.ColumnInfo;
import androidx.room.Entity;
import androidx.room.Ignore;
import androidx.room.PrimaryKey;

import java.io.Serializable;
import java.util.List;

@Entity(tableName = "queryBean")
public class QueryBean implements Serializable {
    @PrimaryKey()
    @ColumnInfo(name = "id")
    @NonNull
    String id;
    @Ignore
    String classid;
    @ColumnInfo(name = "name")
    String name;
    @Ignore
    String peoplenum;
    @Ignore
    String preparetime;
    @Ignore
    String cookingtime;
    @ColumnInfo(name = "content")
    String content;
    @ColumnInfo(name = "pic")
    String pic;
    @Ignore
    String tag;
    @Ignore
    List<MaterialBean> materialBeans;
    @Ignore
    List<ProcessBean> processBeans;

    //数据库用
    public QueryBean(@NonNull String id, String name, String content, String pic) {
        this.id = id;
        this.name = name;
        this.content = content;
        this.pic = pic;
    }

    public QueryBean(String id, String classid, String name, String peoplenum, String preparetime,
                     String cookingtime, String content, String pic, String tag,
                     List<MaterialBean> materialBeans, List<ProcessBean> processBeans) {
        this.id = id;
        this.classid = classid;
        this.name = name;
        this.peoplenum = peoplenum;
        this.preparetime = preparetime;
        this.cookingtime = cookingtime;
        this.content = content;
        this.pic = pic;
        this.tag = tag;
        this.materialBeans = materialBeans;
        this.processBeans = processBeans;
    }

    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    public String getClassid() {
        return classid;
    }

    public void setClassid(String classid) {
        this.classid = classid;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getPeoplenum() {
        return peoplenum;
    }

    public void setPeoplenum(String peoplenum) {
        this.peoplenum = peoplenum;
    }

    public String getPreparetime() {
        return preparetime;
    }

    public void setPreparetime(String preparetime) {
        this.preparetime = preparetime;
    }

    public String getCookingtime() {
        return cookingtime;
    }

    public void setCookingtime(String cookingtime) {
        this.cookingtime = cookingtime;
    }

    public String getContent() {
        return content;
    }

    public void setContent(String content) {
        this.content = content;
    }

    public String getPic() {
        return pic;
    }

    public void setPic(String pic) {
        this.pic = pic;
    }

    public String getTag() {
        return tag;
    }

    public void setTag(String tag) {
        this.tag = tag;
    }

    public List<MaterialBean> getMaterialBeans() {
        return materialBeans;
    }

    public void setMaterialBeans(List<MaterialBean> materialBeans) {
        this.materialBeans = materialBeans;
    }

    public List<ProcessBean> getProcessBeans() {
        return processBeans;
    }

    public void setProcessBeans(List<ProcessBean> processBeans) {
        this.processBeans = processBeans;
    }

    @Override
    public String toString() {
        return "QueryBean{" +
                "id='" + id + '\'' +
                ", classid='" + classid + '\'' +
                ", name='" + name + '\'' +
                ", peoplenum='" + peoplenum + '\'' +
                ", preparetime='" + preparetime + '\'' +
                ", cookingtime='" + cookingtime + '\'' +
                ", content='" + content + '\'' +
                ", pic='" + pic + '\'' +
                ", tag='" + tag + '\'' +
                ", materialBeans=" + materialBeans +
                ", processBeans=" + processBeans +
                '}';
    }
}
